import React from 'react'
import { useLocation } from 'react-router-dom'

function Detail() {
    const location=useLocation()
    const v=location.state
    console.log(v)
  return (
    <div>
      <img src={v.image} alt="" />
      <p>{v.title}</p>
      <p>{v.price}</p>
      <p>{v.date}</p>
    </div>
  )
}

export default Detail
